<%@ page contentType="text/html;charset=UTF-8" %>
<%@ include file="/WEB-INF/views/include/taglib.jsp"%>
<html>
<head>
	<title>建档情况统计</title>
	<meta name="decorator" content="default"/>
	<script src="${ctxStatic}/echarts/childBaseinfoCreateConutEcharts.js" type="text/javascript"></script>
	<script type="text/javascript">
		$(document).ready(function() {
					
		});
		function page(n,s){
			$("#pageNo").val(n);
			$("#pageSize").val(s);
			$("#searchForm").submit();
        	return false;
        }
		function downExcel(){
			top.$.jBox.confirm("确认要导出出入库数据吗？","系统提示",function(v,h,f){
				if(v=="ok"){
					$("#searchForm").attr("action","${ctx}/child/childBaseinfo/exportExcel");
					$("#searchForm").submit();
				}
			},{buttonsFocus:1});
			top.$('.jbox-body .jbox-icon').css('top','55px');
		}
		
		 function reset(){
				$("#searchForm").reset();
				var selectVal = $("form:select");
				for(var i=0;i<selectVal.lengeth;i++){
					selectVal[i].options[0].selected= true;
				}
		} 
	</script>
</head>
<body>
	<ul class="nav nav-tabs">
		<li class="active"><a href="${ctx}/child/childBaseinfo/">建档情况统计</a></li>
<%-- 		<shiro:hasPermission name="child:childBaseinfo:edit"><li><a href="${ctx}/child/childBaseinfo/form">个案信息查询添加</a></li></shiro:hasPermission> --%>
	</ul>
	<form:form id="searchForm" modelAttribute="childBaseinfo" action="${ctx}/child/childBaseinfoCreateCount/" method="post" class="breadcrumb form-search">
		<input id="pageNo" name="pageNo" type="hidden" value="${page.pageNo}"/>
		<input id="pageSize" name="pageSize" type="hidden" value="${page.pageSize}"/>
	<div class="breadcrumb">
		<table class="table table-bordered">	
			<tr>
				<th>地区名称：</th>
				<td>
					<form:select path="area" class="span2 minWidth" onchange="change()">
						<form:option value="" label="--请选择--"/>
						<form:options items="${area}" itemLabel="name" itemValue="code" htmlEscape="false"/>
					</form:select>
				</td>
				<th>出生日期：</th>
				<td><input name="startBirthday" type="text" readonly="readonly" maxlength="20" class="input-mini Wdate"
						value="<fmt:formatDate value="${childBaseinfo.birthday}" pattern="yyyy-MM-dd"/>"
						onclick="WdatePicker({dateFmt:'yyyy-MM-dd',isShowClear:true});"/>&nbsp;至
					<input name="endBirthday" type="text" readonly="readonly" maxlength="20" class="input-mini Wdate"
						value="<fmt:formatDate value="${childBaseinfo.birthday}" pattern="yyyy-MM-dd"/>"
						onclick="WdatePicker({dateFmt:'yyyy-MM-dd',isShowClear:true});"/>
				</td>
			</tr>
			<tr>
				<th>建档日期：</th>
				<td>
					<input name="startUpdateDate" type="text" readonly="readonly" maxlength="20" class="input-mini Wdate"
						value="<fmt:formatDate value="${childBaseinfo.birthday}" pattern="yyyy-MM-dd"/>"
						onclick="WdatePicker({dateFmt:'yyyy-MM-dd',isShowClear:true});"/>&nbsp;至
					<input name="endUpdateDate" type="text" readonly="readonly" maxlength="20" class="input-mini Wdate"
						value="<fmt:formatDate value="${childBaseinfo.birthday}" pattern="yyyy-MM-dd"/>"
						onclick="WdatePicker({dateFmt:'yyyy-MM-dd',isShowClear:true});"/>
				</td>
				<th>
<!-- 				浏览单位： -->
				</th>
				<td>
<%-- 					<form:select path="gender" class="span2 minWidth"> --%>
<%-- 						<form:option value="" label="--请选择--"/> --%>
<%-- 						<form:options items="${fns:getDictList('sex')}" itemLabel="label" itemValue="value" htmlEscape="false"/> --%>
<%-- 					</form:select> --%>
				</td>
			</tr>
 
			<tr>
				<th>儿童状态：</th>
				<td>  
					<form:checkboxes path="situation" items="${fns:getDictList('child_situation')}" itemValue="value"/>
				</td>
 				<th>条码：</th>
  				<td>
					<form:select path="gender" class="span2 minWidth">
					<form:option value="" label="--请选择--"/>
					</form:select>
				</td>
			</tr>
		</table>
	</div>
		<ul class="ul-form breadcrumb">
			<li class="btns"><input id="btnSubmit" class="btn btn-primary" type="submit" value="查询"/></li>
			<li class="btns"><input onclick="reset()"  class="btn btn-primary" type="button" value="重置"/></li>
			<li class="btns"><input onclick="downExcel()"  class="btn btn-primary" type="button" value="导出"/></li>
			<li class="btns"><input onclick="showEcharts()" class="btn btn-primary" type="button" value="隐藏图表"/></li>
			<li class="clearfix"></li>
		</ul>
	</form:form>
	<sys:message content="${message}"/>
	
	<!-- echarts图表 -->
	<div id="showEcharts" style="min-width:750px;height: 300px;margin-bottom:20px;"></div>
	
	<table id="contentTable" class="table table-striped table-bordered table-condensed">
		<thead>
			<tr>
				<th>地区名称</th>
				<th>建档儿童数</th>
				<th>及时建档儿童数</th>
				<th>不及时儿童数</th>
				<th>及时建档率</th>
				<th>本地儿童数</th>
				<th>县内流动儿童数</th>
				<th>市内流动儿童数</th>
				<th>省内流动儿童数</th>
				<th>省外流动儿童数</th>
				<th>港澳台儿童数</th>
				<th>境外儿童数</th>
				<th>其他</th>
			</tr>
		</thead>
		<tbody>
		<c:forEach items="${page.list}" var="childBaseinfoCreateCount">
			<tr>
				 
				<td>
					${childBaseinfoCreateCount.name}
				</td>
				<td>
					${childBaseinfoCreateCount.allnum}
				</td>
				<td>
					${childBaseinfoCreateCount.timely}
				</td>
				<td>
					${childBaseinfoCreateCount.nottimely}
				</td>
				<td>
					${childBaseinfoCreateCount.rate}
				</td>
				<td>
					${childBaseinfoCreateCount.locals}
				</td>
				<td>
					${childBaseinfoCreateCount.county}
				</td>
				<td>
					${childBaseinfoCreateCount.shi}
				</td>
				<td>
					${childBaseinfoCreateCount.bs}
				</td>
				<td>
					${childBaseinfoCreateCount.ws}
				</td>
				<td>
					${childBaseinfoCreateCount.gat}
				</td>
				<td>
					${childBaseinfoCreateCount.jw}
				</td>
				<td>
					${childBaseinfoCreateCount.other}
				</td>
			</tr>
		</c:forEach>
		</tbody>
	</table>
	<div class="pagination">${page}</div>
</body>
</html>